package com.yunduansing.demo.model.menu;

import java.util.List;
import com.yunduansing.demo.entity.MenuEntity;

import lombok.Data;

@Data
public class MenuTreeModel {
    private int id;
    private int pid;
    private String name;
    private String icon;
    private String url;
    private int seq;
    private boolean status;
    private List<MenuTreeModel> children;

    public MenuTreeModel(MenuEntity entity,List<MenuTreeModel> children){
        this.id=entity.getId();
        this.pid=entity.getPid();
        this.name=entity.getName();
        this.icon=entity.getIcon();
        this.url=entity.getUrl();
        this.seq=entity.getSeq();
        this.status=entity.getStatus();
        this.children=children;
    }
}